import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '@/components/Home.vue'
import LoginAndReg from '@/components/LoginAndReg.vue'
import Dept from '@/components/Dept.vue'
import Waybill from '@/components/Waybill.vue'
import Dispatch from '@/components/Dispatch.vue'
import Details from '@/components/Details.vue'
import CustomerList from '@/components/CustomerList.vue'
import Exception from '@/components/Exception.vue'
import KoExceptionProblem from '@/components/KoExceptionProblem.vue'
import Order from '@/components/Order.vue'
import OrderDetail from '@/components/OrderDetail.vue'
import UserOrderDetail from '@/components/UserOrderDetail.vue'
import Billing from '@/components/Billing.vue'
import AddCustomer from '@/components/AddCustomer.vue'
import Workbenches from '@/components/Workbenches.vue'
import PersonalData from '@/components/PersonalData.vue'
import Map from '@/components/Map.vue'
import Scheduling from '@/components/Scheduling.vue'
import Message from '@/components/Message.vue'
import Log from '@/components/Log.vue'
import GoodsManagement from '@/components/GoodsManagement.vue'
import AddressManagement from '@/components/AddressManagement.vue'
import PowerUserMange from '@/components/PowerUserMange.vue'
import Lading from '@/components/Lading.vue'
import Company from '@/components/Company.vue'
import FaPiao from '@/components/FaPiao.vue'
import ReceivableOrder from '@/components/ReceivableOrder.vue'
import ReceivableReconciliation from '@/components/ReceivableReconciliation.vue'
import PartnerManagement from '@/components/PartnerManagement.vue'
import CarManagement from '@/components/CarManagement.vue'
import DriverManagement from '@/components/DriverManagement.vue'
import ReturnOrder from '@/components/ReturnOrder.vue'
import SignOrder from '@/components/SignOrder.vue'
import DingDan from '@/components/DingDan.vue'
import CarT from '@/components/CarT.vue'
import ExceptionT from '@/components/ExceptionT.vue'
import SignOrderDetails from '@/components/SignOrderDetails.vue'
import Kaipiao from '@/components/Kaipiao.vue'
import jiade1 from '@/components/jiade1.vue'
import jiade2 from '@/components/jiade2.vue'




Vue.use(VueRouter)




const routes = [{
  path: '/',
  redirect: '/home'
},
{
  path: '/home',
  component: Home,
  children: [
    {
      path: '/dept', component: Dept,//部门
    },
    {
      path: '/waybill', component: Waybill, name: 'page3'//运单
    },
    {
      path: '/dispatch', component: Dispatch,//运单调度
    },
    {
      path: '/details', component: Details,//运单详情
    },
    {
      path: '/customerList', component: CustomerList,//客（用）户管理
    },
    {
      path: '/exception', component: Exception, name: 'page2', //异常管理
    },
    { path: '/ko', component: KoExceptionProblem },//异常子页面
    { path: '/order', component: Order, name: 'page1' },//订单页面
    { path: '/orderDetail', component: OrderDetail },//客户订单详情页面
    { path: '/userOrderDetail', component: UserOrderDetail },//用户订单详情页面
    { path: '/billing', component: Billing },//开单页面
    { path: '/workbenches', component: Workbenches },//工作台页面
    { path: '/personal', component: PersonalData },//个人资料
    { path: '/map', component: Map },//地图页面
    { path: '/scheduling', component: Scheduling },//订单调度页面
    { path: '/message', component: Message },//消息通知页面
    { path: '/log', component: Log },//日志
    { path: '/goodsManagement', component: GoodsManagement },//货物管理
    { path: '/addressManagement', component: AddressManagement },//地址管理
    { path: '/poweruser', component: PowerUserMange },//员工管理
    { path: '/loding', component: Lading },//提货
    { path: '/addCustomer', component: AddCustomer },//添加客户
    { path: '/company', component: Company },//企业信息
    { path: '/fapiao', component: FaPiao },//发票页面
    { path: '/receivableOrder', component: ReceivableOrder },//应收单页面
    { path: '/receivableReconciliation', component: ReceivableReconciliation },//应收对账单页面
    { path: '/driverManagement', component: DriverManagement },//司机管理页面
    { path: '/carManagement', component: CarManagement },//车辆管理页面
    { path: '/partnerManagement', component: PartnerManagement },//承运商管理页面
    { path: '/signOrder', component: SignOrder },//签收单页面
    { path: '/returnOrder', component: ReturnOrder },//回单页面
    { path: '/dingdan', component: DingDan },//订单统计
    { path: '/carT', component: CarT },//司机业绩统计
    { path: '/et', component: ExceptionT },//异常统计
    { path: '/signOrderDetails', component: SignOrderDetails },//签收单详情
    {path:'/kaipiao',component: Kaipiao},//开票页面
    {path:'/jiade1',component: jiade1},//开票页面
    {path:'/jiade2',component: jiade2},//开票页面
  ]
},
{
  path: '/login',
  component: LoginAndReg,
},

]

const router = new VueRouter({
  routes
})

export default router